import tkinter as tk

root = tk.Tk()
root.title("Tkinter Pack Layout")
root.geometry("600x400")

label1 = tk.Label(master=root, text="Tkinter", bg="red", fg="white")
label2 = tk.Label(master=root, text="Pack Layout", bg="green", fg="white")
label3 = tk.Label(master=root, text="Demo", bg="blue", fg="white")

label1.pack(side=tk.LEFT)
label2.pack(side=tk.LEFT)
label3.pack(side=tk.LEFT)

label4 = tk.Label(master=root, text="Tkinter", bg="red", fg="white")
label5 = tk.Label(master=root, text="Pack Layout", bg="green", fg="white")
label6 = tk.Label(master=root, text="Demo", bg="blue", fg="white")

label4.pack(side=tk.TOP)
label5.pack(side=tk.TOP)
label6.pack(side=tk.TOP)

root.mainloop()
